//
//  NSString(TrimExtensions).m
//  ToDoList
//
// This code file is apart of project "iPhone-ToDo-List" 
// (http://code.google.com/p/iphone-todo-list/)
//
// Copyright (c) 2009 Frank Villasenor
//
// Distributed under the terms of the Lesser GNU General Public License.
// A copy of the license should be with these files. If not, you 
// can retrieve a copy from http://www.gnu.org/licenses/lgpl-3.0.txt
// 

#import "NSString(TrimExtensions).h"


@implementation NSString (TrimExtensions)

//
// Trim white space
- (void)trimWhiteSpace
{
	self = [self stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceCharacterSet]];
}

+ (NSString *)trimWhiteSpaceFrom:(NSString *)stringToTrim
{	
	NSString *stringWithoutWhitespace = [stringToTrim stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceCharacterSet]];
	return stringWithoutWhitespace;
}

@end
